module.exports = function (grunt) {
    var arr = [
        "util.js", "cmd.js", "context.js", "classify.js", "group.js", "layer.js",
        "lottery.js", "me.js", "message.js", "notice.js", "page.js", "page_list.js",
        "result.js", "rights.js", "zxf_page.js"
    ];
    for (var i in arr) {
        grunt.config('uglify.public' + i, {
            src: 'public/all/js/' + arr[i],
            dest: 'build/public/all/js/' + arr[i],
        });
    }
    
    var arr = [
        "public/all/js/pages",
        "public/all/js/rule",
        "public/all/js/logic",
        //"public/all/js",
        "ag/js",
        "ag/js/center",
        "ag/js/game",
        "ag/js/opt",
        "agm/js",
        "agm/js/center",
        "agm/js/opt",
        "referee/js",
        "mobile/js",
        "admin/js",
        "group/js",
        "pc/js",
        "qgc/login/js",
        "asc99/login/js",
        "ug9/login/js",
        "ey55/login/js",
        "wx/js",
        "wx/js/center",
    ]
    for (var i in arr) {
        grunt.config('uglify.all' + i, {
            expand: true,
            src: arr[i] + '/**.js',
            dest: 'build/'
        });
    }

    var arr = ['admin/css/admin.css', 'admin/css/admin_login.css',
        "group/css/admin_login.css", "group/css/group.css",
        //"mobile/css/app.css", "mobile/css/center.css", "mobile/css/login.css",
        //"pc/css/app.css", "pc/css/center.css", "pc/css/login.css",
        "public/all/css/common.css", "public/all/css/pc.css", "public/all/css/phone.css",
        "ag/css/app.css", "ag/css/balls.css", "ag/css/index.css", "ag/css/main2.css",
        "referee/css/agent.css", "referee/css/login.css", "referee/css/main.css",
        ];
    for (var i in arr) {
        grunt.config('cssmin.css' + i, {
            src: arr[i],
            dest: 'build/' + arr[i],
        });
    }
};
